import request from '@/utils/request';

export function loginCheckDoctor(username, userpass) {
    return request({
        url: '/login/doctor',
        method: 'post',
        params: {
            doctorUsername: username,
            doctorPassword: userpass
        }
    });
}

export function checkDoctor(token) {
    return request({
        url: '/login/checkDoctor',
        method: 'post',
        params: {
            token: token
        }
    });
}

export function loginCheckPatient(username, userpass) {
    return request({
        url: '/login/patient',
        method: 'post',
        params: {
            patientUsername: username,
            patientPassword: userpass
        }
    });
}

export function checkPatient(token) {
    return request({
        url: '/login/checkPatient',
        method: 'post',
        params: {
            token: token
        }
    });
}

export function loginCheckAdmin(username, userpass) {
    return request({
        url: '/login/admin',
        method: 'post',
        params: {
            adminUsername: username,
            adminPassword: userpass
        }
    });
}

export function checkAdmin(token) {
    return request({
        url: '/login/checkAdmin',
        method: 'post',
        params: {
            token: token
        }
    });
}
